package com.demo.config;

import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.stereotype.Component;

@Aspect
@Component
public class MyAspect {

    @Pointcut("execution(public * com.demo.test1.service..*.*(..) throws Exception)")
    public void pointcut1(){}


    @Before("pointcut1()")
    public void  before(JoinPoint joinPoint){
        System.out.println("before");
    }

}
